//
//  My5TableViewCell.m
//  UI_元旦豆瓣小集合
//
//  Created by dllo on 16/1/2.
//  Copyright © 2016年 lanou3g. All rights reserved.
//

#import "My5TableViewCell.h"

@implementation My5TableViewCell
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self createCell];
    }return self;
}
- (void)dealloc {
    [_title release];
    [_content release];
    [_guojia release];
    [_category_name release];
    [_address release];
    [_view1 release];
    [_view2 release];
    [_view3 release];
    [_view4 release];
    [_image release];
    [super dealloc];
}


- (void)createCell {
    self.title = [[UILabel alloc] init];
    [self.contentView addSubview:_title];
    [_title release];
    
    self.content = [[UILabel alloc] init];
    [self.contentView addSubview:_content];
    [_content release];
    
    self.guojia = [[UILabel alloc] init];
    [self.contentView addSubview:_guojia];
    [_guojia release];
    
    self.category_name = [[UILabel alloc] init];
    [self.contentView addSubview:_category_name];
    [_category_name release];
    
    self.address = [[UILabel alloc] init];
    [self.contentView addSubview:_address];
    [_address release];
    
    self.view1 = [[UIImageView alloc] init];
    [self.contentView addSubview:_view1];
    [_view1 release];
    
    self.view2 = [[UIImageView alloc] init];
    [self.contentView addSubview:_view2];
    [_view2 release];
    
    self.view3 = [[UIImageView alloc] init];
    [self.contentView addSubview:_view3];
    [_view3 release];
    
    self.view4 = [[UIImageView alloc] init];
    [self.contentView addSubview:_view4];
    [_view4 release];
    self.image = [[UIImageView alloc] init];
    [self.contentView addSubview:_image];
    [_image release];
     
}

-(void)layoutSubviews {
    [super layoutSubviews];
    _title.frame = CGRectMake(20, 30, 150, 30);
    _title.backgroundColor = [UIColor redColor];
    _content.frame = CGRectMake(160, 90, 150, 30);
    _guojia.frame = CGRectMake(160, 110, 80, 30);
    _guojia.backgroundColor = [UIColor redColor];
    _category_name.frame = CGRectMake(160, 140, 80, 30);
    _address.frame = CGRectMake(160, 190, 190, 60);
    _address.backgroundColor = [UIColor redColor];
    _view1.frame = CGRectMake(140, 90, 30, 30);
    _view2.frame = CGRectMake(140, 120, 30, 30);
    _view2.backgroundColor = [UIColor redColor];
    _view3.frame = CGRectMake(140, 150, 30, 30);
    _view4.frame = CGRectMake(140, 180, 30, 30);
    _view4.backgroundColor = [UIColor redColor];
    _image.frame = CGRectMake(20, 90, 100, 150);
    _image.backgroundColor = [UIColor redColor];
    
}




- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
